package com.oracle.client;

import org.springframework.beans.factory.BeanFactory;
import org.springframework.context.support.ClassPathXmlApplicationContext;

import com.oracle.model.Student;
import com.oracle.service.StudentService;

public class Test {
	public static void main(String[] args) throws Exception {
		Student student = new Student();
		student.setId(2);
		student.setName("aaaa");
		BeanFactory beanFactory = new ClassPathXmlApplicationContext("applicationContext.xml");
		StudentService service = (StudentService) beanFactory.getBean("studentService");
		service.addStudent(student);
	}
}
